A compact disc is submitted with this application that contains an appendix of computer program listings; the contents of the compact disc are hereby incorporated by reference. The disc was created on Apr. 16, 2004 and includes a file entitled xe2x80x9cAppendix.txtxe2x80x9d having a size of 18 KB bytes. A duplicate disc is also submitted.
I. Field of the Invention
The present invention generally relates to the fields of computer graphics and virtual reality. More particularly, the present invention relates to systems and methods for performing memory management operations to provide graphical displays of complex virtual environments, including complex virtual environments based on massive models.
II. Background Information
As a result of the advances in computer graphics and computer-aided design (CAD), a wide variety of objects and environments can be modeled and rendered with technical detail and precision. For example, 2D and 3D modeling techniques permit engineering models of mechanical parts and other physical objects to be computer generated for various purposes, such as research and development. In addition, complex environments involving offshore platforms, industrial plants, building complexes and other facilities can be modeled using conventional, computer-aided modeling methods. 3D models of such environments are often used in the architecture, engineering and construction (AEC) sectors and for plant design.
Elements or objects in a complex environment may be represented in a 3D model through polygons. Polygons (such as triangles and quadrilaterals) are closed figures made by joining line segments, wherein each line segment intersects exactly two other line segments. In a 3D model, polygons may be combined to represent the surface(s) of boxes, stairs, windows, walls, floors, pipes, beams and other objects in the modeled environment. Data defining the attributes of each object, including lighting and texture, may also be included in a 3D model.
To render 3D models, conventional graphics systems may be employed. Such graphics systems may be provided with graphics cards that are capable of processing 3D model data to generate and display the modeled environment. While triangle elements can be directly handled and rendered by most graphics cards, other polygon elements in a 3D model (such as four or five-sided polygons) require additional processing before they can be rendered. Such processing may include the triangulation of complex polygon elements into triangles so that it can be directly handled by the graphics hardware and rendered on a display terminal.
With the developments in computer-aided graphics and 3D modeling, there has been an increasing demand for interactive displays and simulation to provide virtual reality. The term virtual reality refers to the use of computer-based simulation of real or imaginary environments that permit a user to perform operations within the simulated environment. In the area of 3D game technology, virtual reality software has been created to provide real-time animation within simulated environments for users. To achieve higher levels of realism, many 3D software games permit users to navigate and/or perform operations (such as lifting, walking, running, jumping, climbing, etc.) in a manner that resembles the real world. For this purpose, the effects of gravity and/or other real-world phenomena (such as collisions) may be simulated in virtual reality applications for 3D game users.
Presently, the ability to provide interactive displays and real-time simulation for complex environments presents many challenges. For example, complex environments can be based on 3D models that are comprised of data representing hundreds of thousands of polygons. Although the throughput of graphics systems has improved over the years, rendering complex environments at interactive frame rates (such as 5 frames/second or higher) is impossible with current applications due to the volume of data that must be processed. For instance, attempts to render complex environments represented by approximately 700,000 or more polygons with current systems will typically cause the screen to freeze or lock when a user tries to navigate through the rendered model.
To overcome such obstacles, some applications eliminate real-world phenomena (such as the effect of gravity and/or collisions) to provide simple navigation features in a complex virtual environment. In such applications, however, the user is often left in a confused state since the user is permitted to navigate through walls, floors and other objects represented in the modeled environment. Further, in some cases, the viewpoint of the user may be positioned within walls or between floors, making it difficult for the user to orientate himself/herself with respect to the rendered frame.
Other applications attempt to provide real-time simulation by reducing the level of detail in the rendered frame and/or eliminating the range of interactive options available to a user. In such applications, however, curved surfaces may appear jagged as opposed to smooth. Further, the user may be limited to basic movements (such as forward, left, right, etc.) that are not practical for most applications. Therefore, while such approaches may improve the frame rate, they fail to provide an acceptable level of visualization and simulation to the user. As a result, past attempts do not provide an effective virtual reality solution for complex environments.
In accordance with embodiments of the present invention, virtual reality (VR) systems are provided for generating displays of a complex virtual environment based on VR file(s). In such VR systems, a method may be provided for performing memory management operations, wherein the method comprises: allocating video memory in graphics hardware of the VR system and allocating accelerated graphics port (AGP) memory as part of system memory of the VR system; pre-loading, prior to simulating and rendering frames of the complex environment, all non-dynamic tessellation elements defined in the VR file(s) into memory, wherein pre-loading includes pre-loading non-dynamic tessellation elements into at least one of the video memory and the AGP memory; determining, after pre-loading all non-dynamic tessellation elements, whether memory space is available in at least one of the video memory and the AGP memory; and if memory space is determined to be available, pre-loading dynamic tessellation elements defined in the VR file(s) into the available memory space of the video memory or the AGP memory.
According to other embodiments of the invention, methods may be provided for performing memory management operations in a virtual reality (VR) system, wherein the VR system being adapted to provide displays of a complex virtual environment based on VR file(s). Such methods may comprise: buffering, in memory of the VR system, vertex data for rendered dynamic tessellation elements; determining, for a dynamic tessellation element to be rendered, whether the dynamic tessellation element was rendered in a previous frame at a tessellation level that is the same as a tessellation level for the element in a frame to be rendered; and when it is determined that the dynamic tessellation element was rendered in a previous frame at the same tessellation level, using the buffered vertex data for the previous rendering of the dynamic tessellation element to facilitate the display of the frame to be rendered.
Consistent with still other embodiments of the invention, a computer program product may be provided for generating interactive displays of a complex virtual environment. The computer program product may include a computer readable medium embodying a computer program, wherein the computer program comprises instructions that are executable by a system to perform a method for performing memory management operations. Consistent with embodiments of the invention, such methods may comprise: allocating video memory in graphics hardware of the VR system and allocating accelerated graphics port (AGP) memory as part of system memory of the VR system; estimating, for a dynamic tessellation element to be rendered, memory space requirements for storing rendering data for the dynamic tessellation element, the rendering data comprising vertex data defining one or more triangles representing the dynamic tessellation element; determining whether there is sufficient memory space available in at least one of the video memory and the AGP memory for storing the rendering data based on the estimated memory space requirements; and using the available memory space in at least one of the video memory and the AGP memory for dynamically tesselating the element when it is determined that there is sufficient memory space for the rendering data.
In accordance with yet additional embodiments of the invention, systems may be provided for performing memory management operations. Such systems may comprise: means for buffering, in memory of a virtual reality (VR) system, vertex data for rendered dynamic tessellation elements; means for determining, for a dynamic tessellation element to be rendered, whether the dynamic tessellation element was rendered in a previous frame at a tessellation level that is the same as a tessellation level for the element in a frame to be rendered; and means for using the buffered vertex data for the previous rendering of the dynamic tessellation element to facilitate the display of the frame to be rendered when it is determined that the dynamic tessellation element was rendered in a previous frame at the same tessellation level.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only, and should not be deemed restrictive of the full scope of the embodiments of the invention.